package com.wanshi.member;

import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor;
import com.spring4all.swagger.EnableSwagger2Doc;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;

@MapperScan("com.wanshi.member.mapper")
@EnableSwagger2Doc
@SpringBootApplication
public class MemberApplication {

    public static void main(String[] args) {

        SpringApplication.run(MemberApplication.class,args);
    }


    /**
     * 分页插件
     * @return
     */
    @Bean
    public PaginationInterceptor paginationInterceptor() {
        PaginationInterceptor paginationInterceptor =
                new PaginationInterceptor();
        return paginationInterceptor;
    }
}
